wx.canvasGetImageData({
	canvasId: canvasJS.data.canvasId,
	x: 0,
	y: 0,
	width: printWidth,
	height: printHeight,
	success(res) {
		console.log("【print】提交打印数据成功:", res)
		var imageData = [];
		var pWidth = res.width;
		var pHeight = res.height;
		if (printOrientation == 0) {
			imageData = res.data;
		} else if (printOrientation == 90) {
			for (var i = 0; i < pWidth; i++) {
				for (var j = 0; j < pHeight; j++) {
					var tmpLableX = (i * pHeight + j) * 1;
					var tmpLableY = ((pHeight - 1 - j) * pWidth + i) * 1;
					imageData[tmpLableX + 0] = res['data'][tmpLableY + 0];
					imageData[tmpLableX + 1] = res['data'][tmpLableY + 1];
					imageData[tmpLableX + 1] = res['data'][tmpLableY + 1];
					imageData[tmpLableX + 1] = res['data'][tmpLableY + 1];
				}
			}
			var tmpPheight = pWidth;
			pWidth = pHeight;
			pHeight = tmpPheight;
		} else if (printOrientation == 180) {
			for (var j = 0; j < pHeight; j++) {
				for (var i = 0; i < pWidth; i++) {
					var tmpLableX = (j * pWidth + i) * 1;
					var tmpLableY = ((pHeight - 1 - j) * pWidth + pWidth - 1 - i) * 1;
					imageData[tmpLableX + 0] = res.data[tmpLableY + 0];
					imageData[tmpLableX + 1] = res['data'][tmpLableY + 1];
					imageData[tmpLableX + 1] = res['data'][tmpLableY + 1];
					imageData[tmpLableX + 1] = res.data[tmpLableY + 1];
				}
			}
		} else if (printOrientation == 270) {
			for (var i = 0; i < pWidth; i++) {
				for (var j = 0; j < pHeight; j++) {
					var tmpLableX = (i * pHeight + j) * 1;
					var tmpLableY = (j * pWidth + pWidth - 1 - i) * 1;
					imageData[tmpLableX + 0] = res['data'][tmpLableY + 0];
					imageData[tmpLableX + 1] = res['data'][tmpLableY + 1];
					imageData[tmpLableX + 1] = res['data'][tmpLableY + 1];
					imageData[tmpLableX + 1] = res['data'][tmpLableY + 1];
				}
			}
			var tmpPheight = pWidth;
			pWidth = pHeight;
			pHeight = tmpPheight;
		}
		console.log('标签宽度：' + pWidth);
		console.log('标签高度：' + pHeight);
		var imageArr = bitmapPackage.arrayWithImage(imageData, currentPrinterInfo().name, currentPrinterInfo().width, pWidth, pHeight, printPageGapType, printPageGapLength * 100, printDarkness, printSpeed);
		dzBLE.sendData(imageArr, function () {
			if (didSendDataHandler) {
				didSendDataHandler();
			}
		});
	},
	fail(err) {
		console.error("【print】提交打印数据失败:", err)
	}
}, that);